package com.jinzhi.jinzhidata.dataobject;

import lombok.Data;
import org.springframework.data.annotation.CreatedDate;
import org.springframework.data.annotation.LastModifiedDate;
import org.springframework.data.jpa.domain.support.AuditingEntityListener;

import javax.persistence.Entity;
import javax.persistence.EntityListeners;
import javax.persistence.Id;
import java.math.BigDecimal;
import java.util.Date;

/**
 * @author vansl
 * @description 积分流水：充值、提现
 */
@Data
@Entity
@EntityListeners(AuditingEntityListener.class)
public class Wallet {

    @Id
    private String walletId;

    private String walletTradeNo;

    private String walletUserId;

    /**
     * 单位为元
     */
    private BigDecimal walletAmount;

    private String walletPayType;

    private String walletTransactionId;

    /**
     * 单位为分
     */
    private BigDecimal walletPay;

    private String walletOperationType;

    private String walletState;

    @CreatedDate
    private Date createTime;

    @LastModifiedDate
    private Date updateTime;

}
